package cn.yzgy.yzgyoa.ucenter.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author Yqsen
 * @since 2019-08-20
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("sys_user")
public class SysUser extends Model<SysUser> {

    private static final long serialVersionUID = 1L;

    /**
     * 系统用户唯一识别码
     */
    @TableId(value = "uid", type = IdType.ID_WORKER)
    private Long id;

    /**
     * 登录名
     */
    private String loginName;

    /**
     * 用户密码
     */
    private String psw;

    /**
     * 密码加密SALT值
     */
    private String salt;

    /**
     * 删除（停用）标志 1正常 0停用
     */
    private Integer state;

    /**
     * 确保精度
     * @return
     */
    @TableField(exist = false)
    private String showId;
    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
